﻿using Pay.Core;
using Pay.DTO;
using Pay.IService;
using Pay.TO;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Pay.Web.Areas.Admin.Controllers
{
    [RouteArea("admin")]
    [RoutePrefix("wxVerificationCode")]
    public class WXVerificationCodeController : AdminController
    {
        private IWXVerificationCodeService _iWXVerificationCodeService;

        public WXVerificationCodeController(IWXVerificationCodeService iWXVerificationCodeService)
        {
            _iWXVerificationCodeService = iWXVerificationCodeService;
        }

        public ActionResult Index()
        {
            return View();
        }

        public JsonResult Gets(WXVerificationCodeQuery query)
        {
            var model = _iWXVerificationCodeService.GetWXVerificationCodes(query);
            return Json(ResultToJson.Json(model), JsonRequestBehavior.AllowGet);
        }

    }
}